<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <meta name="360-site-verification" content="ed795688ce80828a0dd8f5ad9c05e4b1" />
    <link href="css/common.css" rel="stylesheet" type="text/css"/>
    <link href="css/base.css" rel="stylesheet" type="text/css"/>
    <link href="css/supplie.css" rel="stylesheet" type="text/css"/>
    <link href="css/style.css" rel="stylesheet" type="text/css"/>
    <link href="css/style1.css" rel="stylesheet" type="text/css"/>
    <script src="js/jquery-1.8.3.min.js" type="text/javascript"></script>
    <script src="js/jquery.pagination.js" type="text/javascript"></script>
    <script src="js/vue.js" type="text/javascript"></script>
    <script src="js/common_js.js" type="text/javascript"></script>
    <script src="js/footer.js" type="text/javascript"></script>
    <title>闲置资产商业街</title>
    <style>
        [v-cloak] {
            display: none;
        }
    </style>
</head>

<body>
<div class="headerpage"></div>
<section>
    <div>
        <div class="right_style" style="float:none;display: flex;margin: 0 auto;width: 1200px;justify-content:space-around">
            <div class="content_style" id="Total" v-cloak>
                <!--收款账号-->
                <div class="Account_style clearfix">
                    <!-- <div class="add_Bank_card"><a href="#" class="add_btn">设置收款银行卡</a></div>-->
                    <div class="Bank_card clearfix">
                        <div class="Bank_card_style">
                            <div class="Alipay_zh">
                                <span class="logo"><img src="images/icon_1.png" /></span>
                                <span class="bank_name">{{data.totalAmount}}</span>
                                <span class="time">总货值</span>
                            </div>
                        </div>
                        <div class="Bank_card_style">
                            <div class="Alipay_zh">
                                <span class="logo"><img src="images/icon_1.png" /></span>
                                <span class="bank_name">{{data.totalAuctionBids}}</span>
                                <span class="time">总招标个数</span>
                            </div>
                        </div>
                        <div class="Bank_card_style">
                            <div class="Alipay_zh">
                                <span class="logo"><img src="images/icon_1.png" /></span>
                                <span class="bank_name">{{data.totalHistory}}</span>
                                <span class="time">总浏览量</span>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</section>
<div class="clear"></div>
<section>
    <!--内容样式-->
    <div id="mian">
        <!--热门闲置-->
        <div class="clearfix marginbottom">
            <div id="Filter_style">
                <!--条件筛选样式-->
                <div class="Filter" id="Filter">
                    <div class="Filter_list clearfix">
                        <div class="Filter_title"><span>地区筛选：</span></div>
                        <div class="Filter_Entire" style="display: flex;">
                            <select id="pList1" class="pList1" v-cloak>
                                <option value="0">全部</option>
                                <option v-for="(item, index) in data" :value="item.provinceCode">{{item.namecn}}</option>
                            </select>
                            <select id="cList1" class="cList1" v-cloak>
                                <option value="0">全部</option>
                                <option v-for="(item, index) in data" :value="item.cityCode">{{item.namecn}}</option>
                            </select>
                        </div>
                    </div>
                </div>
                <!--列表-->
                <div class="p_list  clearfix" id="List" v-cloak>
                    <ul>
                        <li class="gl-item" v-for="(item, index) in data">
                            <em class="icon_special tejia"></em>
                            <div class="Borders">
                                <div class="img"><a href="#"><img src="http://assets.yungangunite.com/Fp7lNB4WUkL9caqYajLnsl9QF3CT" style="width:220px;height:220px"></a></div>
                                <div class="Price"><b>¥{{item.gross}}万</b><span>[总货值]</span></div>
                                <div class="Shop_name"><a href="#">商家：{{item.name}}</a></div>
                                <div class="Shop_name"><a href="#">编号：{{item.nameEn}}</a></div>
                                <div class="Shop_name"><a href="#">地址：{{item.provinceName}}{{item.cityName}}</a></div>
                                <div class="Shop_name"><a href="#">关注量：{{item.follow}}</a></div>
                                <div class="Shop_name"><a href="#">收藏量：{{item.collection}}</a></div>
                                <div class="Shop_name"><a href="#">招标项目个数：{{item.bids}}</a></div>
                                <div class="p-operate">
                                    <a href="#" class="p-o-btn Collect" :id="item.id" onclick="collect(this)"><em></em>收藏</a>
                                    <a :href="['factoryDetails.html?id='+item.id]" class="p-o-btn shop_cart"><em></em>查看详情</a>
                                </div>
                            </div>
                        </li>
                    </ul>
                </div>
                <div class="empty-wrap" style="display: none">
                    <img src="images/empty.png" alt=""/>
                </div>
            </div>
        </div>
        <div class="Inside_pages">
            <div class="Paging">
                <div class="Pagination  M-box"></div>
            </div>
        </div>
        <div class="footerpage"></div>
        <!--右侧菜单栏购物车样式-->
        <div class="fixedBox">
            <ul class="fixedBoxList">
                <li class="fixeBoxLi user"><a href="msg.html"> <span class="fixeBoxSpan"></span> <strong>消息中心</strong></a></li>
                <li class="fixeBoxLi Service "><span class="fixeBoxSpan"></span> <strong>客服</strong>
                    <div class="ServiceBox">
                        <div class="bjfffs"></div>
                        <dl onclick="javascript:;">
                            <dt><img src="images/Service1.png"></dt>
                            <dd><strong>QQ客服1</strong>
                                <p class="p1">9:00-22:00</p>
                                <p class="p2"><a
                                        href="http://wpa.qq.com/msgrd?v=3&amp;uin=123456&amp;site=DGG三端同步&amp;menu=yes">点击交谈</a>
                                </p>
                            </dd>
                        </dl>
                        <dl onclick="javascript:;">
                            <dt><img src="images/Service1.png"></dt>
                            <dd><strong>QQ客服1</strong>
                                <p class="p1">9:00-22:00</p>
                                <p class="p2"><a
                                        href="http://wpa.qq.com/msgrd?v=3&amp;uin=123456&amp;site=DGG三端同步&amp;menu=yes">点击交谈</a>
                                </p>
                            </dd>
                        </dl>
                    </div>
                </li>
                <li class="fixeBoxLi code cart_bd " style="display:block;" id="cartboxs">
                    <span class="fixeBoxSpan"></span> <strong>微信</strong>
                    <div class="cartBox">
                        <div class="bjfff"></div>
                        <div class="QR_code">
                            <p><img src="images/erweim.jpg" width="180px" height="180px"/></p>
                            <p>微信扫一扫，关注我们</p>
                        </div>
                    </div>
                </li>

                <li class="fixeBoxLi BackToTop"><span class="fixeBoxSpan"></span> <strong>返回顶部</strong></li>
            </ul>
        </div>
    </div>
</section>

<script>
    $(function () {
        $(".headerpage").load("header.html");
        $(".footerpage").load("footer.html");
    });
</script>

<script>

    function collect(e) {
        var id = $(e).attr('id')
        getToken(function (token) {
            ajax('/enterprise/collect/','POST',{enterpriseId:id},token,function (data) {
                alert('收藏成功')
            })
        })
    }

    /*省市级联动*/

    //获取所有省
    var data_p = {data: []};
    var data_c1 = {data: []};
    getToken(function (token) {
        ajax('/pc/','GET','',token,function (data) {
            data_p.data = data.data
        })
    })
    var vuepList1 = new Vue({
        el: '#pList1',
        data: data_p
    });
    var vuecList1 = new Vue({
        el: '#cList1',
        data: data_c1
    });

    var search_params = {
        provinceCode: '0',
        countryCode: '0',
        currPage:1
    }

    //变更搜索条件
    $('.pList1').change(function () {
        var pCode = $('.pList1').val()
        getToken(function (token) {
            ajax('/pc/city/?provinceCode='+pCode,'GET','',token,function (data) {
                data_c1.data = data.data
            })
        })
    })

    $('body').delegate('.cList1','change',function () {
        search_params.countryCode = $('.cList1').val()
        getList()
    })
</script>

<script>
    //总览
    var data_total = {data:[]};
    var vueTotal = new Vue({
        el: '#Total',
        data: data_total
    });
    getToken(function (token) {
        ajax('/enterprise/pool','GET','',token,function (data) {
            data_total.data = data.data
        })
    })


    var data_list = {data:[]};

    var vueList = new Vue({
        el: '#List',
        data: data_list
    });
    getList()
    function getList(api) {
        var url = '/enterprise?pageSize=20';
        for(var key in search_params){
            url += '&'+key+'='+search_params[key]
        }
        getToken(function (token) {
            ajax(url,'GET','',token,function (data) {
                if(data.data.length < 1){
                    $('.empty-wrap').css('display','')
                    initPage(0)
                }else {
                    var total_page = Math.ceil(data.total/search_params.pageSize)
                    if(typeof api == 'object'){
                        api.setPageCount(total_page)
                    }else {
                        initPage(total_page)
                    }
                    $('.empty-wrap').css('display','none')
                }
                for(var i=0;i < data.data.length;i++){
                    data.data[i].beginAt = timestampToTime(data.data[i].beginAt)
                    data.data[i].endAt = timestampToTime(data.data[i].endAt)
                }
                data_list.data = data.data
            })
        })
    }

    function initPage(pageCount) {
        $('.M-box').pagination({
            pageCount: pageCount,
            coping: true,
            prevContent: '上页',
            nextContent: '下页',
            callback: function (api) {
                search_params.currPage = api.getCurrent()
                getList(api)
            }
        });
    }
</script>
<script>
    jQuery(function(){
        jQuery(".fixedBox ul.fixedBoxList li.fixeBoxLi").hover(
            function (){
                jQuery(this).find('span.fixeBoxSpan').addClass("hover");
                jQuery(this).addClass("hover");
            },
            function () {
                jQuery(this).find('span.fixeBoxSpan').removeClass("hover");
                jQuery(this).removeClass("hover");
            }
        );
        jQuery('.BackToTop').click(function(){$('html,body').animate({scrollTop: '0px'}, 800);});
        var oDate=new Date();
        var iHour=oDate.getHours();
        if(iHour>8 && iHour<32){
            jQuery(".Service").addClass("startWork");
            jQuery(".Service").removeClass("Commuting");

        }else{
            jQuery(".Service").addClass("Commuting");
            jQuery(".Service").removeClass("startWork");
        };

    });
</script>
</body>
</html>
